package com.jmz.apt.api.configure;

import java.util.ArrayList;
import java.util.List;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

/**
 * Created by fanglexue on 2019/10/28.
 */
public class ExclusionUrl {
    public static  final List<String> patterns = new ArrayList<String>() {{
        add("login/(.*)?");
        add("admin/convertRole");
    }};

    public  static boolean isInclude(String url){
        for (String pattern : patterns) {
            Matcher matcher = Pattern.compile(pattern).matcher(url);
            if (matcher.matches()) {
                return true;
            }
        }
        return false;
    }

}
